package com.chat.common.common.constant;

public class RedisKeyConstant {
    public static final String REGISTER_USER = "Register:user:";//注册用户信息
    public static final String REGISTER_LOCK = "Register:lock:";//注册用户锁
    public static final String CAPTCHA_MAIL = "Captcha:mail:";//邮箱验证码
    public static final String VOUCHER = "Voucher:";//临时通行证
    public static final String TOKEN_USER = "User:Token:user:";//用户令牌
    public static final String TOKEN_ADMIN = "Token:admin:";//管理员令牌
    public static final String TOKEN_ACCOUNT = "User:Token:account:";
    public static final String USER_ACCOUNT_ForToken = "User:UserAccount:ForToken:";//用户登录信息
    public static final String ADMIN_ACCOUNT_ForToken = "adminAccount:ForToken:";//管理员登录信息

    //发布/订阅
    //在线用户set
    public static final String LOGIN_USER = "Login:user:online";//登录
    public static final String LOGIN_EXIT_USER = "Login:user:offline";//退出登录
    public static final String ONLINE_USERS_SET_KEY = "online:users:set";//用户在线列表

    //客户端基础设置
    public static final String CLIENT_BASIC_SETTING = "Client:Basic:Setting";//客户端基础配置

    public static final String NOTICE = "Notice:";//通知，比如添加好友，加群申请通知，被删除通知，信息修改通知
    public static final String MESSAGE_CACHE = "MESSAGE_CACHE:toUserAccount:";//收到的消息在redis中的缓存，接收者
    public static final String GROUP_MESSAGE_CACHE = "GROUP_MESSAGE_CACHE:toGroupAccount:";//收到的 群 消息在redis中的缓存，接收者
    public static final String MESSAGE_CACHE_FROM = "MESSAGE_CACHE_FROM:";//收到的消息在redis中的缓存，改善者
    public static final String USER_GROUP_CACHE = "USER_GROUP_CACHE:UserId:";//缓存用户在哪些群中
}
